"""
函数快速体验
"""
str1 = "itheima"
str2 = "itcast"
str3 = "python"
# print(len(str1))
count = 0
for i in str1:
    count += 1
print(f"字符串{str1}的长度是{count}")
count = 0
for i in str2:
    count += 1
print(f"字符串{str2}的长度是{count}")
count = 0
for i in str2:
    count += 1
print(f"字符串{str3}的长度是{count}")


# 使用函数

def my_len(data):
    total = 0
    for temp in data:
        total += 1
    print(f"字符串{data}的长度是{total}")


my_len(str1)
my_len(str2)
my_len(str3)
